<!--
 * @Author: Sam
 * @Date: 2020-10-22 12:03:56
 * @LastEditTime: 2020-10-23 11:04:36
 * @LastEditors: Sam
 * @Description: 
 * @FilePath: \thework\ygboost-eui\src\components\app\blank\setting\channel\customerchannel.vue
 * @可以输入预定的版权声明、个性签名、空行等
-->
<template>
  <div>
    客户渠道管理
    <div>
      {{ data }}
    </div>
  </div>
</template>

<script>
import { ajax } from "@/store/yg/common/utils";
import axios from "axios";
export default {
  props: ["data"],
  data() {
    return {
      id: 1,
      row: ""
    };
  },
  mounted() {
    this.onSubmit();
    console.log("data", this.data);
  },
  methods: {
    onSubmit() {
      // if ("" === this.id) {
      //   return;
      // }
      let formData = new FormData();
      formData.append("customerChannelId", 3);
      formData.append("consignmentPlaceId", 11);
      var data = {};
      // data["id"] = this.id;
      var param = {
        customerChannelId: 3,
        consignmentPlaceId: 11
      };

      ajax("queryChannelByIdTest", param).then(
        res => {
          this.row = res;
        },
        error => {
          console.log(error);
        }
      );

      // axios
      //   .post("api/setting/customerchannel/queryChannelById", param)
      //   .then(res => {
      //     console.log(res);
      //   })
      //   .catch(err => {
      //     console.log(err);
      //   });
    }
  }
};
</script>

<style></style>
